from django.db import models
from django.contrib.auth.models import AbstractUser

# Create your models here.

class UserProfile(models.Model):
    username = models.CharField(verbose_name='姓名', max_length=30, blank=True)
    password = models.CharField(verbose_name='身份证后四位', max_length=30, blank=True)
    ticket = models.CharField(verbose_name='登录标志', max_length=30, blank=True)
    is_read = models.BooleanField(verbose_name='是否查阅', default=False, blank=True)
    read_time = models.DateTimeField(verbose_name='查阅时间', blank=True, auto_created=True)

    def __str__(self):
        return self.username

    class Meta:
        verbose_name = '用户信息'
        verbose_name_plural = verbose_name